package cn.csc.module.order.controller.app.order.vo;

import cn.csc.module.shoppingCard.api.transaction.dto.CardTransactionCreateReqDTO;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.List;

/**
 * 订单参数
 *
 * @author
 * @date 2020-12-04 11:27:35
 */
@Data
public class AppOrderItemCreateReqVO {

    @ApiModelProperty(value = " 子订单Id")
    private BigInteger id;

    @ApiModelProperty(value = "商户编码,商户id")
    @NotNull(message = "商户id不能为空")
    private BigInteger shopId;
    @ApiModelProperty(value = "店铺名称")
    @NotNull(message = "店铺名称不能为空")
    private String shopName;
    @ApiModelProperty(value = "类目Id")
    private String categoryId;
    @ApiModelProperty(value = "订单商品spu")
    @NotNull(message = "订单商品id不能为空")
    private BigInteger spuId;

    @ApiModelProperty(value = "产品名称")
    private String spuName;

    @ApiModelProperty(value = "订单商品sku")
    @NotNull(message = "订单商品sku不能为空")
    private BigInteger skuId;

    @ApiModelProperty(value = "sku名称")
    private String skuName;

    @ApiModelProperty(value = "产品价格", required = true)
    private BigDecimal productPrice;

    @ApiModelProperty(value = "产品主图")
    private String pic;
    @ApiModelProperty(value = "sku商品总数")
    @NotNull(message = "sku商品总数不能为空")
    private Integer count;
    @ApiModelProperty(value = "产品总金额", required = true)
    private BigDecimal total;

    @ApiModelProperty(value = "运费备注")
    private String freightRemark;

    @ApiModelProperty(value = "购物卡支付金额")
    private BigDecimal cardPayAmount;
    @ApiModelProperty(value = "实付金额", required = true)
    private BigDecimal spuActualAmount;

    /**
     * 计算金额使用
     */
    BigDecimal remaining;  // 剩余应支付金额

    List <CardTransactionCreateReqDTO> cardUsage;

}
